



$(document).ready(function()
{
     $(document).keydown(function(event)
	{
		switch(event.which){
			case 39:
	  $('#car').css("margin-left","+=10px");
	   break;
	   	case 37:
	   $('#car').css("margin-left","-=10px");
	   break;
	   	case 38:
	   $('#car').css("margin-top","-=1px");
	   break;
	   	case 40:
	   $('#car').css("margin-top","+=1px");
	   break;
	   case 65:
	    $('#glass').effect('explode');
		break;
	    default:
		$('#press').html(event.which);
		}
	});

/*
$(document).on('keypress', function(e) { 
    if (e.keyCode == 97) {               
   	  $('#car').animate({margin: '-= 100px'}, 2000);
    }
});
*/
	
});

